Anomaly detection by self-learning of sensor signals

ABSTRACT

Accurate detection of anomaly in sensor signals is critical and can have an immense impact in the health care domain. Accordingly, identifying outliers or anomalies with reduced error and reduced resource usage is a challenge addressed by the present disclosure. Self-learning of normal signature of an input sensor signal is used to derive primary features based on valley and peak points of the sensor signals. A pattern is recognized by using discrete nature and strictly rising and falling edges of the input sensor signal. One or more defining features are identified from the derived features based on statistical properties and time and frequency domain properties of the input sensor signal. Based on the values of the defining features, clusters of varying density are identified for the input sensor signal and based on the density of the clusters, anomalous and non-anomalous portions of the input sensor signals are classified.

PRIORITY CLAIM

This U.S. patent application claims priority under 35 U.S.C. § 119 to:India Application No. 201621036139 filed on Oct. 21, 2016. The entirecontents of the aforementioned application are incorporated herein byreference.

TECHNICAL FIELD

The embodiments herein generally relate to signal processing, and moreparticularly to systems and methods for anomaly detection byself-learning of sensor signals.

BACKGROUND

Sensor signals are gaining high importance for deriving parametersrequired to build smart applications based on sensor analytics. Henceextracting the various time series features of sensor signals and thenco-relating them with application specific parameters is a necessity toobtain robust sensor analytics applications. However, sensor signalssuch as Photoplethysmograph (PPG) are characterized by a lot of noiseand analytics generally run on low power/battery operated device likemobile phones. Therefore, identifying outlier/anomaly (with or withoutphysiological abnormality) with reduced error and reduced resource usageis an important requirement.

SUMMARY

Embodiments of the present disclosure present technological improvementsas solutions to one or more of the above-mentioned technical problemsrecognized by the inventors in conventional systems.

In an aspect, there is provided a processor implemented methodcomprising: deriving primary features associated with an input sensorsignal based on the discrete nature of the input sensor signal, theprimary features being minima points, maxima points, next minima pointsand three consecutive extrema points, wherein the input sensor signalcomprises a non-anomalous portion thereof; detecting a pattern based onselective derived features obtained from the primary features;identifying at least one defining feature from the derived featuresbased on statistical properties and time and frequency domain propertiesof the input sensor signal; performing self-learning of the input sensorsignal based on the derived features and the at least one definingfeature of the non-anomalous portion of the input sensor signal;clustering portions of the input sensor signal based on values of the atleast one defining feature associated thereof into clusters of varyingdensity; and classifying the portions of the input sensor signal asanomalous portions and non-anomalous portions based on the density ofthe clusters, wherein most dense clusters correspond to non-anomalousportions and least dense clusters correspond to anomalous portions ofthe input sensor signal.

In another aspect, there is provided a system comprising: one or moredata storage devices operatively coupled to the one or more processorsand configured to store instructions configured for execution by the oneor more processors to: derive primary features associated with an inputsensor signal based on the discrete nature of the input sensor signal,the primary features being minima points, maxima points, next minimapoints and three consecutive extrema points, wherein the input sensorsignal comprises a non-anomalous portion thereof; detect a pattern basedon selective derived features obtained from the primary features;identify at least one defining feature from the derived features basedon statistical properties and time and frequency domain properties ofthe input sensor signal; perform self-learning the input sensor signalbased on the derived features and the at least one defining feature ofthe non-anomalous portion of the input sensor signal; cluster portionsof the input sensor signal based on values of the at least one definingfeature associated thereof into clusters of varying density; andclassify the portions of the input sensor signal as anomalous portionsand non-anomalous portions based on the density of the clusters, whereinmost dense clusters correspond to non-anomalous portions and least denseclusters correspond to anomalous portions of the input sensor signal.

In yet another aspect, there is provided a computer program productcomprising a non-transitory computer readable medium having a computerreadable program embodied therein, wherein the computer readableprogram, when executed on a computing device, causes the computingdevice to: derive primary features associated with an input sensorsignal based on the discrete nature of the input sensor signal, theprimary features being minima points, maxima points, next minima pointsand three consecutive extrema points, wherein the input sensor signalcomprises a non-anomalous portion thereof; detect a pattern based onselective derived features obtained from the primary features; identifyat least one defining feature from the derived features based onstatistical properties and time and frequency domain properties of theinput sensor signal; perform self-learning the input sensor signal basedon the derived features and the at least one defining feature of thenon-anomalous portion of the input sensor signal; cluster portions ofthe input sensor signal based on values of the at least one definingfeature associated thereof into clusters of varying density; andclassify the portions of the input sensor signal as anomalous portionsand non-anomalous portions based on the density of the clusters, whereinmost dense clusters correspond to non-anomalous portions and least denseclusters correspond to anomalous portions of the input sensor signal.

In an embodiment of the present disclosure, the derived featuresobtained from the primary features are (i) amplitude of maxima points,(ii) number of sampling points between two consecutive minima points,(iii) amplitude differences between minima points and next followedmaxima points, (iv) number of sampling points between maxima points andnext followed minima points and (v) consecutive amplitude and temporaldifferences of a number of sampling points in a pre-defined time framedetection window to identify the trend thereof.

In an embodiment of the present disclosure, the one or more hardwareprocessors are further configured to represent the detected pattern inthe form of a function of the derived features.

In an embodiment of the present disclosure, the one or more hardwareprocessors are further configured to identify at least one definingfeature by identifying at least one feature from the derived featuressatisfying conditions including: (i) difference between mean values ofthe derived features of non-anomalous portions of the input sensorsignal and the mean values of the derived features of the input sensorsignal is larger than at least a pre-defined first threshold, thepre-defined first threshold being based on the type of the input sensorsignal; and (ii) standard deviation of the derived features of thenon-anomalous portions of the input sensor signal is smaller than thestandard deviation of the derived features of the input sensor signal byat least a pre-defined second threshold, the pre-defined secondthreshold being based on the type of the input sensor signal.

In an embodiment of the present disclosure, the one or more hardwareprocessors are further configured to cluster portions of the inputsensor signal based on values of the at least one defining featureassociated thereof by k-means clustering method. Preferably, inaccordance with the present disclosure, k=3.

In an embodiment of the present disclosure, the one or more hardwareprocessors are further configured to cluster portions of the inputsensor signal by merging of two or more clusters.

It is to be understood that both the foregoing general description andthe following detailed description are exemplary and explanatory onlyand are not restrictive of the embodiments of the present disclosure, asclaimed.

BRIEF DESCRIPTION OF THE DRAWINGS

The embodiments herein will be better understood from the followingdetailed description with reference to the drawings, in which:

FIG. 1 illustrates an exemplary block diagram of a system for anomalydetection by self-learning of sensor signals, in accordance with anembodiment of the present disclosure;

FIG. 2 illustrates an exemplary flow diagram of a method for anomalydetection by self-learning of sensor signals, in accordance with anembodiment of the present disclosure;

FIG. 3 illustrates an exemplary graphical illustration of maxima andminima points detected as part of self-learning of an input sensorsignal, in accordance with an embodiment of the present disclosure;

FIG. 4 illustrates an exemplary graphical illustration of comparativestatistical properties and time and frequency domain properties of aninput sensor signal, in accordance with an embodiment of the presentdisclosure; and

FIG. 5 illustrates a graphical representation of anomaly detected inaccordance with the present disclosure as compared with ground truthdata.

It should be appreciated by those skilled in the art that any blockdiagram herein represent conceptual views of illustrative systemsembodying the principles of the present subject matter. Similarly, itwill be appreciated that any flow charts, flow diagrams, statetransition diagrams, pseudo code, and the like represent variousprocesses which may be substantially represented in computer readablemedium and so executed by a computing device or processor, whether ornot such computing device or processor is explicitly shown.

DETAILED DESCRIPTION

Exemplary embodiments are described with reference to the accompanyingdrawings. In the figures, the left-most digit(s) of a reference numberidentifies the figure in which the reference number first appears.Wherever convenient, the same reference numbers are used throughout thedrawings to refer to the same or like parts. While examples and featuresof disclosed principles are described herein, modifications,adaptations, and other implementations are possible without departingfrom the spirit and scope of the disclosed embodiments. It is intendedthat the following detailed description be considered as exemplary only,with the true scope and spirit being indicated by the following claims.

Before setting forth the detailed explanation, it is noted that all ofthe discussion below, regardless of the particular implementation beingdescribed, is exemplary in nature, rather than limiting.

Detection of normal (non-anomalous) and anomalous events from sensorsignals is a key necessity in today's smart world. In the context of thepresent disclosure, anomalous phenomena indicate outliers that mayencompass noise, mainly due to motion artifacts and/or abnormalities.Identifying patterns from a sensor signal is a challenge speciallywithout using training data. Conventional methods have used supervisedlearning to classify normal and anomalous phenomena. Systems and methodsof the present disclosure provide semi-supervised means to classifynormal and anomalous phenomena by using self-learning of signals,wherein as a first step in the analysis of sensor signals, a pattern ofselective derived features is detected based on temporal and amplitudedifferences of primary features of sensor signals, the primary featuresbeing derived based on the peak and valley points of the sensor signals.Thus, in accordance with the present disclosure, the pattern of thesensor signal is learnt by applying the discrete nature of the sensorsignals and basic definitions of minima and maxima. This is followed byidentifying one or more defining features from the derived primaryfeatures based on statistical learning of normal signature of the sensorsignals. Self-learning encompasses the dynamic variation in patternrecognition to classify anomalous phenomena. A clustering algorithm isthen applied to cluster portions of the input sensor signal based on thevalues of the defining features associated with the portions of theinput sensor signal; depending on the density of the clusters, theanomalous and non-anomalous portions of the sensor signals are thenclassified.

Referring now to the drawings, and more particularly to FIGS. 1 through5, where similar reference characters denote corresponding featuresconsistently throughout the figures, there are shown preferredembodiments and these embodiments are described in the context of thefollowing exemplary system and method.

FIG. 1 illustrates an exemplary block diagram of a system 100 foranomaly detection by self-learning of sensor signals, in accordance withan embodiment of the present disclosure. In an embodiment, the system100 includes one or more processors 104, communication interfacedevice(s) or input/output (I/O) interface(s) 106, and one or more datastorage devices or memory 102 operatively coupled to the one or moreprocessors 104. The one or more processors 104 that are hardwareprocessors can be implemented as one or more microprocessors,microcomputers, microcontrollers, digital signal processors, centralprocessing units, state machines, graphics controllers, logiccircuitries, and/or any devices that manipulate signals based onoperational instructions. Among other capabilities, the processor(s) isconfigured to fetch and execute computer-readable instructions stored inthe memory. In an embodiment, the system 100 can be implemented in avariety of computing systems, such as laptop computers, notebooks,hand-held devices, workstations, mainframe computers, servers, a networkcloud and the like.

The I/O interface device(s) 106 can include a variety of software andhardware interfaces, for example, a web interface, a graphical userinterface, and the like and can facilitate multiple communicationswithin a wide variety of networks N/W and protocol types, includingwired networks, for example, LAN, cable, etc., and wireless networks,such as WLAN, cellular, or satellite. In an embodiment, the I/Ointerface device(s) can include one or more ports for connecting anumber of devices to one another or to another server.

The memory 102 may include any computer-readable medium known in the artincluding, for example, volatile memory, such as static random accessmemory (SRAM) and dynamic random access memory (DRAM), and/ornon-volatile memory, such as read only memory (ROM), erasableprogrammable ROM, flash memories, hard disks, optical disks, andmagnetic tapes. In an embodiment, one or more modules (not shown) of thesystem 100 can be stored in the memory 102.

FIG. 2 illustrates an exemplary flow diagram of a method 200 for anomalydetection by self-learning of sensor signals, in accordance with anembodiment of the present disclosure. In an embodiment, the system 100comprises one or more data storage devices or memory 102 operativelycoupled to the one or more processors 104 and is configured to storeinstructions configured for execution of steps of the method 200 by theone or more processors 104.

In an embodiment, at step 202, the one or more processors 104 may obtainan input sensor signal wherein at least a portion of the input sensorsignal is non-anomalous (normal signature) and may be used forself-learning at step 212. Accordingly a window of the normal signatureof input sensor signal based on ground truth may be provided as an inputto the system 100 for learning primary features associated with peak andvalley points of the input sensor signal. Following the discrete natureof the input sensor signal, at step 204, the one or more processors 104may derive the primary features associated with the input sensor signalincluding minima points, maxima points, next minima points and threeconsecutive extrema points. In accordance with the present disclosure,selective features from the primary features are derived at step 206 fordetecting a pattern associated with the input sensor signal at step 208.In an embodiment, the derived features include:

-   (i) X1=amplitude of maxima points,-   (ii) X2=number of sampling points between two consecutive minima    points,-   (iii) X3=amplitude differences between minima points and next    followed maxima points,-   (iv) X4=number of sampling points between maxima points and next    followed minima points and-   (v) X5=consecutive amplitude and temporal differences of a number of    sampling points in a pre-defined time frame detection window to    identify trends among them.    In the context of the present disclosure, the detection window may    be a 300 millisecond window.

In an embodiment, the step of detecting a pattern based on selectivederived features may further comprise representing the detected patternin the form of a function of the derived features. For instance,Pattern=f(X1, X2, X3, X4, X5)

In an embodiment, a semi-supervised approach is used to identify, atstep 210, at least one defining feature from the derived features basedon statistical properties and time and frequency domain properties ofthe input sensor signal. For each of the derived features of each of theinput sensor signal, mean (μ) and standard deviation (σ) is computed forthe normal signature or non-anomalous portion of the input sensorsignal. The one or more defining features are those derived featuresthat satisfy the following two conditions—

-   (i) difference between mean values of the derived features of    non-anomalous portions of the input sensor signal and the mean    values of the derived features of the input sensor signal is    significantly large; in an embodiment the difference is larger than    at least a pre-defined first threshold, the pre-defined first    threshold being based on the type of the input sensor signal; and-   (ii) standard deviation of the derived features of the non-anomalous    portions of the input sensor signal is significantly smaller than    the standard deviation of the derived features of the input sensor    signal; in an embodiment the standard deviation of the derived    features of the non-anomalous portions of the input sensor signal is    smaller than the standard deviation of the derived features by at    least a pre-defined second threshold, the pre-defined second    threshold being based on the type of the input sensor signal.    In an embodiment, the pre-defined first threshold and the    pre-defined second threshold may have same values.    The aforementioned two conditions may be further understood from the    description of Table 1 and Table 2 herein below.

Once the self-learning process, at step 212, based on the non-anomalousportion of the input sensor signal is completed, the one or moreprocessors 104 may cluster, at step 214, portions of the input sensorsignal based on values of the at least one defining feature associatedwith the input sensor signal into clusters of varying density. In anembodiment, the step of clustering portions of the input sensor signalis based on k-means clustering method. In a preferred embodiment of thepresent disclosure, the step of clustering portions of the input sensorsignal is based on 3-means clustering method with k=3. In an embodiment,the step of clustering comprises merging of two or more of the clusters.For instance, lower density clusters having insignificant members incomparison to dense clusters may be merged to detect anomalous portionsof the input sensor signal. In an embodiment, along with the density ofthe clusters, the nearness among the cluster's centroids may also betaken into account, if necessary for merging.

In an embodiment, at step 216, the one or more processors 104 mayclassify portions of the input sensor signal as anomalous portions andnon-anomalous portions based on the density of the clusters. In anembodiment, most dense clusters may be classified as corresponding tonon-anomalous portions and least dense clusters may be classified ascorresponding to anomalous portions of the input sensor signal. Inaccordance with the present disclosure, it is presumed that percentageof normal part of the input sensor signal is more than that of theanomalous part. Classification of normal and anomalous portions is basedon ground truth. Systems and methods of the present disclosure thusenable automating anomaly detection for any sensor signal as compared toprior art wherein domain specific features are considered and anomalydetection relies on supervised learning.

Empirical Evaluation: Fingertip PPG data was collected from persons inthe age group 20 to 50 years. Total duration of the collected data was 5minutes with 30 seconds normal and 10 seconds motion artifacts where thepersons moved their finger multiple times. The system of the presentdisclosure used a sample of normal non-noisy data (30 seconds) forself-learning. During the self-learning phase, the system of the presentdisclosure derives maxima and minima by following strictly rising andfalling edges and the discrete nature of the signal. For instance,minima points are detected as follows:

${\overset{\sim}{x}}_{k - \frac{T\; 2}{2}} > {{\overset{\sim}{x}}_{k - \frac{T\; 2}{2} + 1}\mspace{14mu}\ldots} > {\overset{\sim}{x}}_{k - 1} > {\overset{\sim}{x}}_{k} < {{\overset{\sim}{x}}_{k + 1}\mspace{14mu}\ldots} < {\overset{\sim}{x}}_{k + \frac{T\; 2}{2}}$wherein, T2 is a detection window of 300 milliseconds, {tilde over (x)}is a smoothened signal applying moving average technique. FIG. 3illustrates an exemplary graphical illustration of maxima and minimapoints detected as part of self-learning of an input sensor signal, inaccordance with an embodiment of the present disclosure. After detectingthe minima and maxima points, the system of the present disclosurediscovers pattern of the normal (non-anomalous) portion as well ascomplete signal by deriving X1, X2, X3 and X4 and is followed byselection of the defining feature. Illustrations of means and standarddeviations are shown in Table 1, Table 2 whereas FIG. (corresponding toTable 1) illustrates an exemplary graphical illustration of comparativestatistical properties and time and frequency domain properties of theinput sensor signal, in accordance with an embodiment of the presentdisclosure. Particularly, FIG. 4 illustrates the average of X1, X2, X3and X4 for 9 signals collected for the evaluation.

TABLE 1 Statistical deviations of different features for an exemplarysignal 1 Data: Non-anomalous (Normal) portion Data: Complete of theinput input sensor Derived sensor signal signal features (μ) (σ) (μ) (σ)X1 60.66667 2.216819 66.71631 16.09806 X2 48.00 1.75662 45.3262417.62121 X3 36.11111 2.561002 48.19149 17.36454 X4 34.91667 1.5 28.1560310.68797

TABLE 2 Statistical deviations of different features for an exemplarysignal 2 Difference Difference Data: Non-anomalous Between Between Std.(Normal) portion of the Data: Complete Mean (Data: Deviation (Data:Derived input sensor signal input sensor signal Normal − Data: Normal −Data: features (μ) (σ) (μ) (σ) Complete) Complete) X1 3.45757 0.0808153.297586 0.384283 0.159984361 0.303468717 X2 100.5714 6.925148 97.0707528.87905 3.500673854 21.95390534 X3 1.859346 0.15215 1.511768 0.5910440.347577673 0.438893477 X4 71.89286 6.154428 64.87264 23.428137.020215633 17.27370377It may be noted from Table 2 that for each of X2 and X4, the differencebetween mean values of normal and the complete portion of the signal issignificantly large (3.5 and 7.02 for X2 and X4 respectively), and thestandard deviation for the normal part is significantly smaller thanthat of the complete signal (with a difference of 21.95 and 17.27 for X2and X4 respectively). In the context of this example, the pre-definedfirst threshold may have been set as say 2; wherein both X2 and X4having difference between mean values of normal and the complete portionof the signal as 3.5 and 7.02 respectively qualify as defining features.Also, the pre-defined second threshold may have been set as say 15;wherein both X2 and X4 having a difference of 21.95 and 17.27 qualify asdefining features. Therefore, X2 and X4 in the data under considerationsatisfy the two conditions required to qualify as the defining featuresof the method present disclosure. Clustering is performed using X2 andX4 with the help of k-means algorithm with k=3, where the dense clusterindicates the normal phenomenon and least dense cluster indicatesanomalous phenomenon. Lower density clusters were merged (havinginsignificant members in comparison to the dense cluster) to detect theanomalous samples of the signal. The detected anomaly was compared withground truth to assess the performance of the system and method of thepresent disclosure. FIG. 5 illustrates a graphical representation ofanomaly detected in accordance with the present disclosure as comparedwith ground truth data.

TABLE 3 performance measure of the detected anomaly for the exemplarysignal 1 Performance (%) Anomalous subsequence detection Precision 90.27Sensitivity 92.09

From the above described empirical evaluation using real fieldquasi-periodic photoplethysmogram (PPG) signal with (or without) motionartifacts, it may be noted that 90% accuracy was achieved in detectinganomalous phenomena in the signal by the system and method of thepresent disclosure. PPG signals have an immense impact on cardiac healthmonitoring, stress, blood pressure, and SPO2 (saturation of peripheraloxygen) measurement. Accordingly, systems and methods of the presentdisclosure can have several applications particularly in the healthcaredomain.

The written description describes the subject matter herein to enableany person skilled in the art to make and use the embodiments of thepresent disclosure. The scope of the subject matter embodiments definedhere may include other modifications that occur to those skilled in theart. Such other modifications are intended to be within the scope ifthey have similar elements that do not differ from the literal languageof the claims or if they include equivalent elements with insubstantialdifferences from the literal language.

It is, however to be understood that the scope of the protection isextended to such a program and in addition to a computer-readable meanshaving a message therein; such computer-readable storage means containprogram-code means for implementation of one or more steps of themethod, when the program runs on a server or mobile device or anysuitable programmable device. The hardware device can be any kind ofdevice which can be programmed including e.g. any kind of computer likea server or a personal computer, or the like, or any combinationthereof. The device may also include means which could be e.g. hardwaremeans like e.g. an application-specific integrated circuit (ASIC), afield-programmable gate array (FPGA), or a combination of hardware andsoftware means, e.g. an ASIC and an FPGA, or at least one microprocessorand at least one memory with software modules located therein. Thus, themeans can include both hardware means and software means. The methodembodiments described herein could be implemented in hardware andsoftware. The device may also include software means. Alternatively, theembodiments of the present disclosure may be implemented on differenthardware devices, e.g. using a plurality of CPUs.

The embodiments herein can comprise hardware and software elements. Theembodiments that are implemented in software include but are not limitedto, firmware, resident software, microcode, etc. The functions performedby various modules comprising the system of the present disclosure anddescribed herein may be implemented in other modules or combinations ofother modules. For the purposes of this description, a computer-usableor computer readable medium can be any apparatus that can comprise,store, communicate, propagate, or transport the program for use by or inconnection with the instruction execution system, apparatus, or device.The various modules described herein may be implemented as softwareand/or hardware modules and may be stored in any type of non-transitorycomputer readable medium or other storage device. Some non-limitingexamples of non-transitory computer-readable media include CDs, DVDs,BLU-RAY, flash memory, and hard disk drives.

Further, although process steps, method steps, techniques or the likemay be described in a sequential order, such processes, methods andtechniques may be configured to work in alternate orders. In otherwords, any sequence or order of steps that may be described does notnecessarily indicate a requirement that the steps be performed in thatorder. The steps of processes described herein may be performed in anyorder practical. Further, some steps may be performed simultaneously.

The illustrated steps are set out to explain the exemplary embodimentsshown, and it should be anticipated that ongoing technologicaldevelopment will change the manner in which particular functions areperformed. These examples are presented herein for purposes ofillustration, and not limitation. Further, the boundaries of thefunctional building blocks have been arbitrarily defined herein for theconvenience of the description. Alternative boundaries can be defined solong as the specified functions and relationships thereof areappropriately performed. Alternatives (including equivalents,extensions, variations, deviations, etc., of those described herein)will be apparent to persons skilled in the relevant art(s) based on theteachings contained herein. Such alternatives fall within the scope andspirit of the disclosed embodiments. Also, the words “comprising,”“having,” “containing,” and “including,” and other similar forms areintended to be equivalent in meaning and be open ended in that an itemor items following any one of these words is not meant to be anexhaustive listing of such item or items, or meant to be limited to onlythe listed item or items. It must also be noted that as used herein andin the appended claims, the singular forms “a,” “an,” and “the” includeplural references unless the context clearly dictates otherwise.

It is intended that the disclosure and examples be considered asexemplary only, with a true scope and spirit of disclosed embodimentsbeing indicated by the following claims.

What is claimed is:
 1. A processor implemented method (200) for anomalydetection in an input sensor signal, comprising: deriving primaryfeatures associated with the input sensor signal based on discretenature of the input sensor signal, the primary features being minimapoints, maxima points, next minima points and three consecutive extremapoints (204), wherein the input sensor signal comprises a non-anomalousportion thereof; detecting a pattern associated with the input sensorsignal based on selective derived features obtained from the primaryfeatures (206, 208) and representing the detected pattern in the form ofa function of the derived features; identifying, using a semi-supervisedapproach, at least one defining feature from the derived features basedon statistical properties and time and frequency domain properties ofthe input sensor signal (210), wherein the identified defining featuresare the derived features that satisfy conditions including: (i)difference between mean values of the derived features of thenon-anomalous portion of the input sensor signal and the mean values ofthe derived features of complete portion of the input sensor signal islarger than at least a pre-defined first threshold, the pre-definedfirst threshold being based on the type of the input sensor signal; and(ii) standard deviation of the derived features of the non-anomalousportion of the input sensor signal is smaller than the standarddeviation of the derived features of complete portion of the inputsensor signal by at least a pre-defined second threshold, thepre-defined second threshold being based on the type of the input sensorsignal; performing self-learning of the input sensor signal based on thederived features and the at least one defining feature of thenon-anomalous portion of the input sensor signal (212); clusteringportions of the input sensor signal based on values of the at least onedefining feature associated thereof into clusters of varying density(214); and automatically classifying the portions of the input sensorsignal as anomalous portions and non-anomalous portions based on thedensity of the clusters (216) and ground truth, wherein most denseclusters correspond to non-anomalous portions and least dense clusterscorrespond to anomalous portions of the input sensor signal, whereinself-learning of the input sensor signal encompasses dynamic variationin pattern recognition to classify the anomalous portions andnon-anomalous portions.
 2. The processor implemented method of claim 1,wherein the derived features obtained from the primary features are (i)amplitude of maxima points, (ii) number of sampling points between twoconsecutive minima points, (iii) amplitude differences between minimapoints and next followed maxima points, (iv) number of sampling pointsbetween maxima points and next followed minima points and (v)consecutive amplitude and temporal differences of a number of samplingpoints in a pre-defined time frame detection window to identify trendsthereof.
 3. The processor implemented method of claim 1, wherein thestep of clustering portions of the input sensor signal based on valuesof the at least one defining feature associated thereof is based onk-means clustering method.
 4. The processor implemented method of claim3, wherein the step of clustering portions of the input sensor signal isbased on 3-means clustering method with k=3.
 5. The processorimplemented method of claim 1, wherein the step of clustering comprisesmerging of two or more of the clusters.
 6. A system (100) for anomalydetection in an input sensor signal, comprising: one or more datastorage devices (102) operatively coupled to one or more hardwareprocessors (104) and configured to store instructions configured forexecution by the one or more hardware processors to: derive primaryfeatures associated with the input sensor signal based on discretenature of the input sensor signal, the primary features being minimapoints, maxima points, next minima points and three consecutive extremapoints, wherein the input sensor signal comprises a non-anomalousportion thereof; detect a pattern associated with the input sensorsignal based on selective derived features obtained from the primaryfeatures) and represent the detected pattern in the form of a functionof the derived features; identify, using a semi-supervised approach, atleast one defining feature from the derived features based onstatistical properties and time and frequency domain properties of theinput sensor signal, wherein the identified defining features are thederived features that satisfy conditions including: (i) differencebetween mean values of the derived features of the non-anomalous portionof the input sensor signal and the mean values of the derived featuresof complete portion of the input sensor signal is larger than at least apre-defined first threshold, the pre-defined first threshold being basedon the type of the input sensor signal; and (ii) standard deviation ofthe derived features of the non-anomalous portion of the input sensorsignal is smaller than the standard deviation of the derived features ofcomplete portion of the input sensor signal by at least a pre-definedsecond threshold, the pre-defined second threshold being based on thetype of the input sensor signal; perform self-learning the input sensorsignal based on the derived features and the at least one definingfeature of the non-anomalous portion of the input sensor signal; clusterportions of the input sensor signal based on values of the at least onedefining feature associated thereof into clusters of varying density;and classify automatically, the portions of the input sensor signal asanomalous portions and non-anomalous portions based on the density ofthe clusters and ground truth, wherein most dense clusters correspond tonon-anomalous portions and least dense clusters correspond to anomalousportions of the input sensor signal, wherein self-learning of the inputsensor signal encompasses dynamic variation in pattern recognition toclassify the anomalous portions and non-anomalous portions.
 7. Thesystem of claim 6, wherein the derived features obtained from theprimary features are (i) amplitude of maxima points, (ii) number ofsampling points between two consecutive minima points, (iii) amplitudedifferences between minima points and next followed maxima points, (iv)number of sampling points between maxima points and next followed minimapoints and (v) consecutive amplitude and temporal differences of anumber of sampling points in a pre-defined time frame detection windowto identify the trend thereof.
 8. The system of claim 6, wherein the oneor more hardware processors are further configured to cluster portionsof the input sensor signal based on the values of the at least onedefining feature associated thereof based on k-means clustering method.9. The system of claim 8, wherein the one or more hardware processorsare further configured to cluster portions of the input sensor signalbased on 3-means clustering method with k=3.
 10. The system of claim 6,wherein the one or more hardware processors are further configured tocluster portions of the input sensor signal by merging of two or moreclusters.
 11. A computer program product comprising a non-transitorycomputer readable medium having a computer readable program embodiedtherein, wherein the computer readable program, when executed on acomputing device, causes the computing device to: derive primaryfeatures associated with an input sensor signal based on the discretenature of the input sensor signal, the primary features being minimapoints, maxima points, next minima points and three consecutive extremapoints, wherein the input sensor signal comprises a non-anomalousportion thereof; detect a pattern associated with the input sensorsignal based on selective derived features obtained from the primaryfeatures and represent the detected pattern in the form of a function ofthe derived features; identify, using a semi-supervised approach, atleast one defining feature from the derived features based onstatistical properties and time and frequency domain properties of theinput sensor signal, wherein the identified defining features are thederived features that satisfy conditions including: (i) differencebetween mean values of the derived features of the non-anomalous portionof the input sensor signal and the mean values of the derived featuresof complete portion of the input sensor signal is larger than at least apre-defined first threshold, the pre-defined first threshold being basedon the type of the input sensor signal; and (ii) standard deviation ofthe derived features of the non-anomalous portion of the input sensorsignal is smaller than the standard deviation of the derived features ofcomplete portion of the input sensor signal by at least a pre-definedsecond threshold, the pre-defined second threshold being based on thetype of the input sensor signal; perform self-learning of the inputsensor signal based on the derived features and the at least onedefining feature of the non-anomalous portion of the input sensorsignal; cluster portions of the input sensor signal based on values ofthe at least one defining feature associated thereof into clusters ofvarying density; and classify automatically, the portions of the inputsensor signal as anomalous portions and non-anomalous portions based onthe density of the clusters and ground truth, wherein most denseclusters correspond to non-anomalous portions and least dense clusterscorrespond to anomalous portions of the input sensor signal, whereinself-learning of the input sensor signal encompasses dynamic variationin pattern recognition to classify the anomalous portions andnon-anomalous portions.